package com.hmall.common.myClient;

import com.hmall.common.pojo.Address;
import com.hmall.common.pojo.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "userservice")
public interface UserClient {


    @GetMapping("/user/{id}")
    User findById(@PathVariable(value = "id") Long id);


    @GetMapping("/address/{id}")
    Address findAddressById(@RequestParam(value = "id") Long id);
}
